package com.wljy.developtool.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.wljy.developtool.dto.QpsQueryDTO;
import com.wljy.developtool.dto.QpsQueryDetailsDTO;
import com.wljy.developtool.entity.MetricApiEntity;
import com.wljy.developtool.vo.QpsQueryVO;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.time.LocalDateTime;
import java.util.List;

@Mapper
public interface MetricApiMapper extends BaseMapper<MetricApiEntity> {

    List<QpsQueryDTO> qpsQuery(@Param("query") QpsQueryVO qpsQueryVO);

    List<QpsQueryDetailsDTO> getQpsByDayTime(@Param("dayTime") String dayTimes);

    List<QpsQueryDTO> appQps(@Param("app") String app,
                             @Param("beginTime") LocalDateTime beginTime,
                             @Param("endTime") LocalDateTime endTime);
}
